home *** CD-ROM | disk | FTP | other *** search
/ Aminet 21 / Aminet 21 (1997)(GTI - Schatztruhe)[!][Oct 1997].iso / Aminet / dev / misc / FD2Pragma.lha / FD2Pragma.doc next >
Encoding:
Text File  |  1997-08-02  |  25.2 KB  |  595 lines

  1. This is a utility to create:
  2.   - following pragma statements for certain C compilers: amicall, libcall,
  3.     tagcall and syscall
  4.   - proto files for C compilers
  5.   - offset (LVO) files for assembler programs
  6.   - stub functions for either tag-functions or all library functions
  7.   - stub functions as assembler text
  8.   - stub functions as useable link library file
  9.   - FD files out of pragma files
  10.   - stubs for C++ compilers (SPECIAL 10 and 11 and CLIB)
  11.   - the files with your own headers inserted
  12.   - files for using local pointers for shared library bases in compilers
  13.     which do not support this normally
  14.   - stub functions for Pascal compilers
  15.  
  16. Therefor only the FD file telling the library informations is needed. For
  17. CSTUBS function and SPECIAL options 10-13 you may additionally supply the
  18. CLIB keyword giving FD2Pragma the prototypes file in clib directory.
  19.  
  20. Special option 50 does the reverse to normal: convert pragma to FD!
  21.  
  22. Calling the program seems to be (is) very difficult, but it offers you a
  23. large set of functions. A lot of options need a lot of abilities to turn
  24. them on/off!
  25.  
  26. Read this documentation very carefully, because there are some notes you
  27. may not see on fast reading, but which will help you a lot. (for example
  28. HEADER option and "" filename)
  29.  
  30. *--------------------------------------------------------------------------*
  31.  
  32. You get the command template with FD2Pragma ? .
  33.  
  34. FROM=FDFILE/A,SPECIAL/N,TO/K,COMMENT/S,MODE/N,AMICALL/K,LIBCALL/K,AMITAGS/K,
  35. LIBTAGS/K,CSTUBS/K,EXTERNC/S,USESYSCALL/S,CLIB/K,PRIVATE/S,HEADER/K,
  36. STORMFD/S:
  37.  
  38. In this position you may press <?> again and you get the following text!
  39. Be carefull, because this text is longer than one normal high resolution
  40. screen, so it is usefull to press a key in the middle of the text to stop
  41. the output.
  42.  
  43. FDFILE:  the FD file which should be used
  44. SPECIAL: 1 - Aztec compiler (xxx_lib.h,     MODE 2, AMICALL)
  45.      2 - DICE compiler  (xxx_pragmas.h, MODE 3, LIBCALL)
  46.      3 - SAS compiler   (xxx_pragmas.h, MODE 3, LIBCALL,LIBTAGS)
  47.      4 - MAXON compiler (xxx_lib.h,     MODE 1, AMICALL)
  48.      5 - STORM compiler (xxx_lib.h,     MODE 1, AMITAGS,AMICALL)
  49.      6 - all compilers [default]
  50.     10 - stub-functions for C - assembler text
  51.     11 - stub-functions for C - link library
  52.     12 - defines and link library for local library base (register call)
  53.     13 - defines and link library for local library base (stack call)
  54.     14 - stub-functions for Pascal - assembler text
  55.     15 - stub-functions for Pascal - link library
  56.     20 - assembler lvo _lvo.i file
  57.     21 - assembler lvo _lib.i file
  58.     22 - assembler lvo _lvo.i file no XDEF
  59.     23 - assembler lvo _lib.i file no XDEF
  60.     30 - proto file with pragma/..._lib.h call
  61.     31 - proto file with pragma/..._pragmas.h call
  62.     32 - proto file with pragmas/..._lib.h call
  63.     33 - proto file with pragmas/..._pragmas.h call
  64.     34 - proto file with local/..._loc.h call
  65.     35 - proto file for all compilers
  66.     50 - FD file (source is a pragma file!)
  67. TO:     the destination directory (self creation of filename) or
  68.      the destination file
  69. COMMENT: copy comments found in FD file
  70. MODE:     SPECIAL 1-6,AMICALL,LIBCALL,AMITAGS,LIBTAGS,CSTUBS:
  71.      1 - _INCLUDE_PRAGMA_..._LIB_H definition method [default]
  72.      2 - _PRAGMAS_..._LIB_H definition method
  73.      3 - _PRAGMAS_..._PRAGMAS_H definition method
  74.      4 - no definition
  75.      SPECIAL 10-13:
  76.      0 - all functions, normal interface
  77.      1 - only tag-functions, tagcall interface [default]
  78.      2 - all functions, normal and tagcall interface
  79. AMICALL: creates amicall pragmas
  80. LIBCALL: creates libcall pragmas
  81. AMITAGS: creates tagcall pragmas (amicall like method (StormC++))
  82. LIBTAGS: creates tagcall pragmas (libcall like method (SAS C))
  83. CSTUBS:  creates stub functions in C code
  84. The last five need a string as argument. This string is used to set
  85. a #if<given string> before the set method.
  86. EXTERNC: add a #ifdef __cplusplus ... statement to pragma file
  87. USESYSCALL: uses syscall pragma instead of libcall SysBase
  88. CLIB:    name of the prototypes file in clib directory
  89. PRIVATE: includes private declared functions
  90. HEADER:  inserts given file into header of created file ("" is scan)
  91. STORMFD: converts FD files of strange StormC++ format
  92.  
  93. *--------------------------------------------------------------------------*
  94.  
  95. Useful examples (with intuition.library):
  96.  
  97. 1) FD2Pragma <fd file> TO <pragma dir>
  98.  
  99.    FD2Pragma FD:intuition_lib.h TO INCLUDE:pragma/
  100.  
  101.     Creates a pragma file for all C compilers and copies it to the
  102.     given directory.
  103.  
  104. 2) FD2Pragma <fd file> CLIB <clib file> SPECIAL 11 TO <lib dir>
  105.  
  106.    FD2Pragma FD:intuition_lib.h CLIB INCLUDE:clib/intuition_protos.h
  107.      SPECIAL 11 TO LIB:
  108.  
  109.     Creates a link library holding stub functions to call tag-functions
  110.     from compilers which do not support them (MaxonC++).
  111.  
  112. 3) FD2Pragma <fd file> CLIB <clib file> SPECIAL 12 MODE 2
  113.  
  114.    FD2Pragma FD:intuition_lib.fd CLIB INCLUDE:clib/intuition_protos.h
  115.      SPECIAL 12 MODE 2
  116.  
  117.     Creates a link library and an include file which allow you to call
  118.     library functions with local base variables in compilers which do
  119.     not support that (MaxonC++). See below, how to handle these files.
  120.  
  121. 4) FD2Pragma <fd file> SPECIAL 34 TO <proto dir>
  122.  
  123.    FD2Pragma FD:intuition_lib.h SPECIAL 34 TO INCLUDE:proto/
  124.  
  125.     Creates a proto file for the local library base file include, which
  126.     was created in example 3 and copies it to the given directory.
  127.  
  128. 5) FD2Pragma <fd file> SPECIAL 35 TO <proto dir>
  129.  
  130.    FD2Pragma FD:intuition_lib.h SPECIAL 35 TO INCLUDE:proto/
  131.  
  132.     Creates a proto file for all C compilers and copies it to the
  133.     given directory.
  134.  
  135. *-------------------------------------------------------------------------*
  136.  
  137. The options:
  138.  
  139. *---- all user options ----*
  140.  
  141. FDFILE is the always needed source file, which describes the library.
  142.  
  143. SPECIAL option:
  144.  
  145. (create a pragma file)
  146.   1: Creates a pragma file for the Aztec compiler, what this means you
  147.      see in the brackets above.
  148.   2: Same as 1 for DICE compiler.
  149.   3: Same as 1 for SAS compiler.
  150.   4: Same as 1 for MAXON compiler.
  151.   5: Same as 1 for STORM compiler.
  152.   6: This option creates a pragma file useable for nearly all compilers.
  153.      This is default, when no other mode is given.
  154.  
  155. (link libraries and their assembler code)
  156.  10: Creates STUB functions for C compilers, which are not able to call
  157.      a library directly (result is ASM source code), accepts option CLIB to
  158.      create additional function names for C++ compilers like MaxonC++.
  159.  
  160.  11: Same as 10, but the result as a link library, which can be used by the
  161.      C compiler directly.
  162.  
  163.  12: Creates two files (a link library and a C include) which allows you to
  164.      use local library base variables also in compilers, which do normally
  165.      not support them (MaxonC++). Most time it is useful to set option
  166.      MODE to 2. This options needs CLIB keyword for correct results.
  167.  
  168.  13: Same as 12, but parameters are passed on stack.
  169.  
  170.  14: Creates STUB functions for Pascal compilers. The tagcall function
  171.      names are ignored, as they cannot be used with Pascal. The result is
  172.      readable assembler text. The code equals the one for C compilers, but
  173.      the args are taken from stack in reversed order.
  174.  
  175.  15: same as 14, but produces link library.
  176.  
  177. (assembler LVO files)
  178.  20: Creates lvo file for an assembler.
  179.  21: Same as 20, but other name.
  180.  22: Same as 20, but there are no XDEF statements in the resulting file.
  181.  23: Same as 22, but other name.
  182.  
  183. (proto files - no prototypes)
  184.  30,31,32,33,34: Creates proto files for the C compiler (the difference is
  185.      in the name of the called file).
  186.  35: Creates proto file with calls inline file for GNU-C and
  187.      pragma/xxx_lib.h for all the others.
  188.  FD2Pragma knows the correct library base structures for some libraries.
  189.  All the other libraries get 'struct Library' as default.
  190.  
  191. (FD file)
  192.  50: This creates a FD file! The option FDFILE has to be a pragma file
  193.      here!
  194.  
  195. TO: Here you specify either the destination directory or the destination
  196.     file!
  197.   - If this argument is a directory, the internal names are used, but the
  198.     file will be in the given directory.
  199.   - If this argument is a filename (not existing or already existing), then
  200.     the resulting file has the here given name!
  201.  
  202. *---- sometimes useful or needed settings ----*
  203.  
  204. COMMENT: Comments which are in the FD file are copied to the pragma or LVO
  205. file, when this option is given!
  206.  
  207. MODE:
  208. 1) given with SPECIAL 1 to 6, AMITAGS, AMICALL, LIBTAGS, LIBCALL or CSTUBS:
  209.    - Defines, which #ifdef ...\n#define ... statement is used in the pragma
  210.      file. Option 1 is default.
  211.  
  212. 2) given with SPECIAL 10 to 13:
  213.    - Defines, which functions should be created. Option 1 is default.
  214.      0 - all functions are taken in normal way with normal name
  215.      1 - only tag-functions are taken with tagcall method and tag name
  216.      2 - means 0 and 1 together
  217.  
  218. EXTERNC: This options adds an #ifdef __cplusplus ... statement to the 
  219. pragma file. This options is useful for C compilers runing in C++ mode, but
  220. it seems, that they do not really need this statement. Only useful with
  221. SPECIAL option 1-6, 12 and 13.
  222.  
  223. USESYSCALL: Instructs FD2Pragma to use the syscall pragma instead of a
  224. libcall SysBase. This is useful only, when using a SPECIAL option with
  225. LIBCALL or by giving LIBCALL directly and converting exec_lib.fd. I think
  226. only SAS compiler supports this statement.
  227.  
  228. CLIB: Supply name of the prototypes file in clib directory. If this option
  229. is given together with SPECIAL 10 to 11, additional functions names with
  230. C++ names are created. FD2Pragma knows all standard parameter types defined
  231. in exec/types.h and dos/dos.h, all structures and some more types. All
  232. other #typedef's bring a warning. Do not use them in prototypes files!
  233. This parameter is needed by option CSTUBS and SPECIAL 12 and 13. If it is
  234. not given you get a nearly useless result.
  235.  
  236. PRIVATE: Also gives you the pragmas or LVO's of private functions.
  237. Normally these functions should never be used!
  238.  
  239. HEADER: This option gives you the ability to specify a file, which should
  240. be inserted after the normal headers and before the clib call of standard
  241. headers (in LVO and ASM files too). If you give "" as filename, the
  242. destination file (if already exists) will be scanned for an existing header.
  243.  
  244. STORMFD: This option allows to convert FD files in strange StormC++ format.
  245. It's a FD file format defining the C tag-function name directly in FD file.
  246. These files cannot be used with other FD scanners without changes.
  247.  
  248. *---- professional user options ----*
  249.  
  250. The now following options are for experts only. They are designed to be used
  251. without any SPECIAL option, but you also can give SPECIAL and any of the
  252. following options! In this case the corresponding settings of SPECIAL are
  253. overwritten, when they are in conflict.
  254.  
  255. AMICALL: creates amicall pragmas
  256. --> #pragma amicall(IntuitionBase,0x294,SetGadgetAttrsA(a0,a1,a2,a3))
  257.  
  258. LIBCALL: creates libcall pragmas
  259. --> #pragma libcall IntuitionBase SetGadgetAttrsA 294 BA9804
  260.  
  261. AMITAGS: creates tagcall pragmas (amicall like method (StormC++))
  262. --> #pragma tagcall(IntuitionBase,0x294,SetGadgetAttrs(a0,a1,a2,a3))
  263.  
  264. LIBTAGS: creates tagcall pragmas (libcall like method (SAS C))
  265. --> #pragma tagcall IntuitionBase SetGadgetAttrs 294 BA9804
  266.  
  267. CSTUBS: creates stub functions in C code. For this option additionally the
  268. CLIB keyword is needed.
  269.  
  270. These five functions need a string as argument. It is used to set a
  271.  
  272.   #if<given string>
  273.  
  274. before the data of that option. So it is possible to create a file like
  275. this:
  276.  
  277. --> FD2Pragma FDFILE xxx AMICALL " defined(__MAXON__) || defined(AZTEC_C)"
  278.     LIBCALL "def __SASC"
  279.  
  280. #if defined(__MAXON__) || defined(AZTEC_C)
  281.   /* do amicalls */
  282. #endif
  283. #ifdef __SASC
  284.   /* do libcalls */
  285. #endif
  286.   
  287. If you give "" as string, then no '#if<text>' statement will be added.
  288.  
  289. As you see, the text is added without space after '#if'. This gives you the
  290. ability to use also other '#if' clauses, than '#ifdef' (f.e. #ifndef). If
  291. needed, you have to add the space in the parameter text (" defined...").
  292.  
  293. *--------------------------------------------------------------------------*
  294.  
  295. Useful include system for C compilers:
  296.  
  297. After programming a long time I arranged my includes in a way, that all my
  298. C compilers are able to use the system includes in one directory.
  299.  
  300. I copied all Amiga system includes to one directory and added some files,
  301. which were created with FD2Pragma. The system includes you get for example
  302. on Amiga Developer CD.
  303.  
  304.  - New directory 'pragma' contains xxx_lib.h pragma files for every
  305.    library. These files were created with SPECIAL option 6.
  306.  - New directory 'proto' contains xxx.h proto files which were created with
  307.    with SPECIAL option 35.
  308.  - New directory 'inline' contains xxx.h inline files for GCC. These files
  309.    were created with fd2inline.
  310.  Directories like 'pragmas' were deleted, when existing. Remain should only
  311.  'clib', 'pragma', 'proto' and library specific directories (like 'dos',
  312.  'exec', 'libraries' and 'utility').
  313.  
  314. All the others (ANSI-C stuff, compiler specials) were copied to annother
  315. directory. In S:User-StartUp I use 'Assign ADD' to join the two directories,
  316. so that the compiler may access both.
  317.  
  318. *--------------------------------------------------------------------------*
  319.  
  320. About created link libraries (SPECIAL Option 11-13):
  321.  
  322. The created link libraries are relatively big compared to other link
  323. libraries. The size of the link library has nothing to do with the size of
  324. the resulting program you create. The code part of my link libraries is
  325. relatively short, but I define a lot of texts (which are NOT copied to the
  326. created executable program). These texts are for easier identification and
  327. every function also gets different names:
  328.  
  329.   1) the normal asm name:  <name>        (f.e.  CopyMem)
  330.   2) the normal C name:   _<name>        (f.e. _CopyMem)
  331.   3) the normal C++ name:  <name>_<params>    (f.e.  CopyMem_PvPvUj)
  332.   4) when a function parameter is STRPTR, a second C++ name is created
  333.  
  334. Forms 3 and 4 occur only, when you use CLIB keyword. With SPECIAL options
  335. 12 and 13 the number of strings is twice as much. The different names give
  336. a lot more flexibility and only make the link library bigger. These names
  337. are only visible to the linker program. The resulting executable most time
  338. is a lot smaller than the link library!
  339.  
  340. I think the code part of the link libraries is optimized as good as
  341. possible. There may be some things making the code shorter, but this will
  342. be in the area of 2 to 10 bytes for some functions. There is no need to
  343. program hours and hours for 10 bytes. The stub functions of amiga.lib are
  344. still a little bit better than mine, but amiga.lib only holds standard
  345. system libraries.
  346.  
  347. *--------------------------------------------------------------------------*
  348.  
  349. About created proto file (SPECIAL Option 35):
  350.  
  351. This file allows supports following define.
  352.  
  353.  __NOLIBBASE__
  354.  
  355.  When this is set before calling the proto file, the declaration of the
  356.  global library base is skipped, so that can be done in source-code. This
  357.  define is also used for GCC.
  358.  
  359. *--------------------------------------------------------------------------*
  360.  
  361. The first #ifdef/#define statements of created C includes:
  362.  
  363. FD2Pragma has a set of different define names for different include files.
  364. These names are internally to allow double-inclusion of one include files
  365. without getting errors. Standard system includes use the same system.
  366.  
  367. The normal names are: (example intuition.library)
  368.  proto files:                _PROTO_INTUITION_H
  369.  local library base files:        _INCLUDE_PROTO_INTUITION_LOC_H
  370.  standard pragma files:            _INCLUDE_PRAGMA_INTUITION_LIB_H
  371.  
  372. Non-FD2Pragma names are:
  373.  inline files for GCC            _INLINE_INTUITION_H
  374.  clib files                CLIB_INTUITION_PROTOS_H
  375.  other includes    (path_name_extension)    INTUITION_INTUITION_H
  376.  
  377. These names never should be used in other files or sources! This rule is
  378. broken for some standard system includes, but is generally true. It may be
  379. some seconds faster, when you check these names before #include line, but
  380. in this case the names must be standard and they are not.
  381.   
  382. *--------------------------------------------------------------------------*
  383.  
  384. Known bugs and problems:
  385.  
  386. - FD2Pragma handles function pointers given as arguments incorrect.
  387.   (example: RawDoFmt() function.). This error only occurs, when using CLIB
  388.   option. I had no time to do this, because it is not the easiest stuff.
  389.   If really needed, please tell me!
  390.   If you use SPECIAL option 12 and 13 you have to correct the corresponding
  391.   data in the .h file and to add extern "C" or extern "ASM" to that name
  392.   (in C++ mode).
  393.  
  394. - cia_lib.fd conversion fails with no ##basename error. This is wanted by
  395.   Amiga OS programmers to allow passing the library base as first argument.
  396.   In this case the C compiler function call does not work. You may add a
  397.   ##basename statement to the fd file and get a working pragma file, but
  398.   this file will not work together with clib/cia_protos.h. Using option
  399.   12 or 13 may bring you a valid link file to use with clib file.
  400.  
  401. - mathieeedoubtrans_lib.fd and mathieeedoubbas_lib.fd both use 2 registers
  402.   for one double value. FD2Pragma creates files for these, but I cannot say
  403.   if they are valid.
  404.  
  405. - Using created graphics pragma brings an error on GetOutlinePen. This is
  406.   not my fault, but an include error. Remove the line
  407.     #define GetOutlinePen(rp) GetOPen(rp)
  408.   in graphics/gfxmacros.h or turn it around to
  409.     #define GetOPen(rp) GetOutlinePen(rp)
  410.   as this works ok.
  411.  
  412. - The redefines of SPECIAL 12 and 13 are illegal, when a function has same
  413.   name as a structure. (f.e. DateStamp of dos.library). You have to remove
  414.   the #define line for that function.
  415.  
  416. *--------------------------------------------------------------------------*
  417.  
  418. The local library base files:
  419.  
  420. When using SPECIAL options 12 and 13 you get two files called libname_loc.h
  421. and libname_loc.lib. The second one is a link library and should be passed
  422. to the compiler with program settings or in makefile. The first one is a C
  423. header file and should be used as a replacement for files in clib, pragma,
  424. proto and pragmas directories. Use always the libname_loc.h file instead of
  425. these files and not together with them! Do not mix them.
  426. I suggest copying the header file into a directory called "local".
  427.  
  428. This file holds prototypes equal to the prototypes in directory clib, but
  429. with struct Library * as first parameter and the name prefix LOC_. Together
  430. with the prototypes there are some defines redefining the function name to
  431. the old one and passing the library base as first parameter. These defines
  432. allow you to use the local library bases as normal as global bases. For
  433. tag-functions and some exceptions these defines do not work and you have
  434. to call the LOC_ function directly and pass the library base as first
  435. parameter.
  436.  
  437. Use always the CLIB keyword together with SPECIAL option 12 and 13 or the
  438. resulting files are nearly useless.
  439.  
  440. *--------------------------------------------------------------------------*
  441.  
  442. How the header scan works:
  443.  
  444. Giving the HEADER option lets FD2Pragma insert the file (you have to give
  445. filename with HEADER option) at start of LVO/Pragma/Proto/stub file. When
  446. you pass "" as filename, FD2Pragma scans the destination file (if already
  447. existing) for a header and copies this header to the new file.
  448.  
  449. How is scanned:
  450.  
  451. FD2Pragma scans for a block of comment lines. So when a line starting with
  452. '*', ';' or '//' is found, this line is the first header line. The header
  453. ends before the first line not starting this way. Additionally, when
  454. FD2Pragma finds first a line starting with '/*' it scans until a line holds
  455. '*/'. This then is the last line of header.
  456.  
  457. C and ASM files are scanned same way, so sometimes FD2Pragma may get a
  458. wrong header.
  459.  
  460. *--------------------------------------------------------------------------*
  461.  
  462. How are tag-functions handled:
  463.  
  464. The tag-functions are supported by certain comments. Note, that the official
  465. includes from the Native Developer Update Kit do not have these comments
  466. included. Lets look at an excerpt from the fd file muimaster_lib.fd:
  467.  
  468. MUI_NewObjectA(class,tags)(a0,a1)
  469. *tagcall
  470. MUI_DisposeObject(obj)(a0)
  471. MUI_RequestA(app,win,flags,title,gadgets,format,params)(d0,d1,d2,a0,a1,a2,a3)
  472. *tagcall
  473. MUI_AllocAslRequest(type,tags)(d0,a0)
  474. *tagcalltags
  475.  
  476. The comments tell us, that MUI_NewObjectA, MUI_RequestA and
  477. MUI_AllocAslRequest should have stub routines. The respective names are
  478. MUI_NewObject, MUI_Request (as the comment has just the word tagcall) and
  479. MUI_AllocAslRequestTags (as the comment has the word tags included).
  480.  
  481. Another possibility would be to write something like
  482.  
  483. SystemTagList(command,tags)(d1/d2)
  484. *tagcall-TagList+Tags
  485.  
  486. This would create a stub routine or tagcall pragma SystemTags (dropping the
  487. word TagList, adding the word Tags).
  488.  
  489. FD2Pragma is also able to create the names automatically. Most times this
  490. should be enough, so you do not have to use the above mentioned method.
  491. In case you really use the above method, I suggest using always the one
  492. with '+' and '-' signs!
  493.  
  494. Tag-functions in standard Amiga includes differ a bit in there naming
  495. conventions, so it is easy to find them:
  496.  
  497. normal function name        tag-function name
  498.  
  499. xxxA                xxx
  500. xxxTagList            xxxTags
  501. xxxArgs                xxx
  502.  
  503. Also the arguments given in the FD file may define a function as tag-
  504. function. If the last argument equals one of the words "tags", "taglist" or
  505. "args", then the function has a tag-function named xxxTags or xxxArgs.
  506.  
  507. *--------------------------------------------------------------------------*
  508.  
  509. Words and phrases:
  510.  
  511. stub, stub function:
  512.  A stub functions is a function, which converts between different inter-
  513.  faces. For example C supplies function parameters on stack, but Amiga
  514.  libraries get them in registers. A stub function for that gets the
  515.  arguments on stack, copies them into the registers and call's the Amiga
  516.  function. Newer C compilers have #pragmas to do that internally, but some
  517.  calling mechanisms are not supported by all compilers. MaxonC++ for
  518.  example does not support the tagcall.
  519.  
  520. pragma:
  521.  C allows non standard (compiler private) definitions called pragmas. Most
  522.  Amiga compilers use them to define system library calls. There exists 5
  523.  different #pragma statements, which are used by different compilers.
  524.  
  525. inline system calls:
  526.  GNU-C (GCC) uses a different system to call Amiga system functions. The
  527.  needed files are stored in a directory called inline. FD2Pragma does not
  528.  produce these files, as they are really GCC specific and there is a fine
  529.  tool (Aminet dev/gcc/fd2inline_bin.lha) to create them. But I suggest
  530.  using the proto file you can create with SPECIAL 35 instead of the file
  531.  you may produce with fd2inline, as the fd2inline proto works with GCC
  532.  only.
  533.  
  534. .lib file, link library:
  535.  A link library is a file holding functions, which are added to the final
  536.  executable at linking time. The other method are runtime or shared
  537.  libraries (#?.library) which are called in runtime and thus take no space
  538.  in the executable program.
  539.  
  540. tag-functions:
  541.  C allows to have functions getting a variable number of parameters,
  542.  everytime they are called. These varargs functions have in there
  543.  prototypes "..." at the end (f.e. printf). Amiga system libraries use this
  544.  mechanism for supplying so called tags. (See Amiga programmers
  545.  documentation for that.)
  546.  The name tag-functions is not the best, because there are also some
  547.  functions getting variable args, which are no tags (f.e. Printf), but it
  548.  expresses good, what is meant.
  549.  
  550. proto file:
  551.  C compilers like SAS have a special directory called proto with files in it
  552.  calling the pragma and prototypes files. This is useful, because different
  553.  compilers store their pragma files in different directories (or use other
  554.  methods to define system calls), but all use one proto file. I did not use
  555.  them till now and called the pragma files directly, but this makes it
  556.  harder to switch to another compiler. So I now try to use proto always.
  557.  
  558. clib-files, prototypes
  559.  For Amiga C functions the prototypes needed in C compilers are stored in
  560.  a directory called clib. The files are named libname_protos.h. The CLIB
  561.  option needs the name of such a file as parameter. These files are needed
  562.  by FD2Pragma to create correct data with some options. If not given, all
  563.  variables will be of type ULONG, which seems not to be the best.
  564.  
  565. *--------------------------------------------------------------------------*
  566.  
  567. This program is in the public domain. Use it as you want, but WITHOUT ANY
  568. WARRANTY!
  569.  
  570. I want to send greetings also to the author making version 2.0 of this
  571. utility. Although this version of FD2Pragma has not much same with version
  572. 2.0 it was a big help. The source code for version 2.0 is included in the
  573. archive and the authors address is also stated in the source file of the
  574. current version!
  575.                     Thanks Jochen for your great work!
  576.  
  577. Because FD2Pragma is very complex, it may be that there are some errors
  578. (maybe also serious ones) in the code. So if you find one, please tell me!
  579. I will also be glad if someone tells me what can be improved in the program!
  580. I will add new options, but a GUI will never come, because this utility is
  581. for experts, and they do not need a GUI for creating the needed files. :-)
  582.  
  583. Please contact me:
  584.  
  585. ****************************************************************************
  586. * snail-mail:                  * e-mail:                                   *
  587. *   Dirk Stoecker              *   stoecker@rcs.urz.tu-dresden.de          *
  588. *   Geschwister-Scholl-Str. 10 *   stoecker@amigaworld.com                 *
  589. *   01877 Bischofswerda        * world wide web:                           *
  590. *   GERMANY                    *   http://home.pages.de/~Gremlin/          *
  591. * phone:                       * pgp key:                                  *
  592. *   GERMANY +49 (0)3594/706666 *   get with finger or from WWW pages       *
  593. ****************************************************************************
  594.  
  595.